<?php


namespace Cblood\Container;

/**
 * @method static Container container
 *
 * Class Overall
 * @package Cblood\Container
 */
class Overall
{
    /**
     * 用来装全局变量的
     * 格式 array (
     *      'container' => Object
     * )
     * @var array
     */
    protected static $properties = [];

    public static function bind(array $properties)
    {
        static::$properties = array_merge(static::$properties, $properties);
    }

    public static function __callStatic($name, $arguments)
    {
        return array_key_exists($name, static::$properties) ? static::$properties[$name] : null;
    }
}